.tab-box-normalize {
    position: relative;
    display: inline-block;

    .tab-contrl {
        height: 48px; // background-color: rgba(241, 241, 241, 1);

        &>label {
            display: inline-block;
            box-sizing: border-box;
            cursor: pointer;
            z-index: 1;
        }
    }

    .tab-container {
        display: inline-block;

        &>.tab-toggle {
            width: 100%; // z-index: -1;

            &>.tab-decoration {
                position: relative;
                padding-left: 16px;
                padding-right: 32px;
                height: 48px;
                line-height: 48px;
                border-radius: 3px 3px 0 0; // border: 1px solid transparent;
            }

            &>.tab-content {
                @include box_sizing();
                padding: 16px;
                display: none;
                position: absolute;
                left: 0; // top: 0 !important;
                top: 48px; // padding-top: 48px;
                // height: 100%;
                background-color: #fff;
                border-radius: 3px;
                z-index: 1;
            }
        }

        &>input[type="radio"] {
            display: none;
        }

        &>input[type="radio"]:checked+.tab-toggle>.tab-decoration {
            background-color: #fff;
            color: $theme_color; // border: 1px #cdcdcd solid;
            border-bottom: 1px $theme_color solid;
            animation: tabFadeIn .4s;
        }

        &>input[type="radio"]:checked+.tab-toggle>.tab-content {
            display: block; // border: 1px #cdcdcd solid;
            animation: tabFadeIn .4s;
        }
    }
}

@keyframes tabFadeIn {
    0% {
        // display: block !important;
        transform: translateY(-12px);
        opacity: 0.6;
    }

    50% {
        transform: translateY(-2px);
    }

    100% {
        // background-color: blue;
        transform: translateY(0px);
        opacity: 1;
    }
}

.tab-box-smooth {
    position: relative;
    display: inline-block;

    .tab-contrl {
        height: 48px; // background-color: rgba(241, 241, 241, 1);

        &>label {
            display: inline-block;
            box-sizing: border-box;
            cursor: pointer;
            z-index: 1;
        }

        &>input[type="radio"] {
            display: none;
        }

        &>input[type="radio"]:checked+label .tab-toggle>.tab-decoration {
            background-color: #fff;
            color: $theme_color; // border: 1px #cdcdcd solid;
            border-bottom: 1px $theme_color solid; // animation: tabFadeIn .4s;
        }

        &>input[type="radio"]:checked+label .tab-toggle>.tab-content {
            // display: block; // border: 1px #cdcdcd solid;
            // animation: tabFadeIn .4s;
            left: 0;
        }

        &>input[type="radio"]:checked+label~label .tab-toggle>.tab-content {
            // display: block; // border: 1px #cdcdcd solid;
            // animation: tabFadeIn .4s;
            left: 100%;
        }
    }

    .tab-container {
        display: inline-block;

        &>.tab-toggle {
            width: 100%; // z-index: -1;

            &>.tab-decoration {
                position: relative;
                padding-left: 16px;
                padding-right: 32px;
                height: 48px;
                line-height: 48px;
                border-radius: 3px 3px 0 0; // border: 1px solid transparent;
            }

            &>.tab-content {
                @include box_sizing();
                padding: 16px; // display: none;
                position: absolute;
                left: -100%; // top: 0 !important;
                top: 48px; // padding-top: 48px;
                // height: 100%;
                background-color: #fff;
                border-radius: 3px;
                z-index: 1;
                transition: all .3s;
            }
        }
    }
}

.tab-overflow-fix {
    overflow-y: -webkit-paged-x;
}

// .tab-box-tb {
//     position: relative;
//     display: inline-block;

//     .tab-contrl {
//         height: 100%;
//         z-index: 1;

//         &>label {
//             position: relative;
//             // display: block;
//             box-sizing: border-box;
//             cursor: pointer;
//             z-index: 2;
//             // background-color: #fff;
//         }

//         &>input[type="radio"] {
//             display: none;
//         }

//         &>input[type="radio"]:checked+label>.tab-decoration {
//             background-color: #fff;
//             color: $theme_color;
//             border-bottom: 1px $theme_color solid;
//         }

//         &>input[type="radio"]:checked+label>.radio-out {
//             border-color: $text_b;
//         }

//         &>input[type='radio']:checked+label>.radio-out>.radio-in {
//             border-color: $text_b;
//             opacity: 1;
//         }

//         // 正常状态
//         &>input[type="radio"]:checked+label+.tab-content {
//             top: 100%; // left: 0;
//             // display: block;
//             visibility: visible;
//             // position: relative;
//             opacity: 1;
//             z-index: 1;
//         }

//         // 上飘
//         &>input[type="radio"]:checked+label~label+.tab-content {
//             top: 200%; // left: 100%;
//             // display: none;
//             visibility: hidden;
//             // position: absolute;
//             opacity: 0;
//             z-index: -1;
//         }

//         // 下飘
//         &>.tab-content {
//             @include box_sizing();
//             position: absolute; // left: -100%;
//             top: -100%; // top: 48px;
//             background-color: #fff;
//             border-radius: 3px; // z-index: 1;
//             transition: top .2s ease-out, opacity .2s ease-out, visibility .2s ease-out; // display: none;
//             visibility: hidden;
//             opacity: 0;
//             z-index: -1; // overflow: hidden;
//         }
//     }

//     .tab-decoration {
//         display: inline-block;
//         // width: 100%;
//         position: relative;
//         padding-left: 16px;
//         padding-right: 32px;
//         height: 48px;
//         line-height: 48px;
//         border-radius: 3px 3px 0 0;

//         &>.tab-toggle {
//             &>.tab-decoration {}
//         }
//     }
// }

// .tab-box-lr {
//     position: relative;
//     display: inline-block;

//     .tab-contrl {
//         height: 48px;

//         &>label {
//             display: inline-block;
//             box-sizing: border-box;
//             cursor: pointer;
//             z-index: 1;
//         }

//         &>input[type="radio"] {
//             display: none;
//         }

//         &>input[type="radio"]:checked+label .tab-toggle>.tab-decoration {
//             background-color: #fff;
//             color: $theme_color;
//             border-bottom: 1px $theme_color solid;
//         }

//         &>input[type="radio"]:checked+label+.tab-content {
//             left: 0;
//             visibility: visible;
//             opacity: 1;
//             z-index: 1;
//         }

//         //这里换成新dom结构后有问题，无法实现回溯，故无法生效
//         &>input[type="radio"]:checked+label~label+.tab-content {
//             // top: 100%;  
//             left: 100%;
//             visibility: hidden;
//             opacity: 0;
//             z-index: -1;
//         }

//         &>.tab-content {
//             @include box_sizing();
//             position: absolute;
//             left: -100%;
//             top: 48px;
//             background-color: #fff;
//             border-radius: 3px; // z-index: 1;
//             transition: opacity .2s ease-out, visibility .2s ease-out; // display: none;
//             visibility: hidden;
//             opacity: 0;
//             z-index: -1; // overflow: hidden;
//         }
//     }

//     .tab-container {
//         display: inline-block;

//         &>.tab-toggle {
//             width: 100%;

//             &>.tab-decoration {
//                 position: relative;
//                 padding-left: 16px;
//                 padding-right: 32px;
//                 height: 48px;
//                 line-height: 48px;
//                 border-radius: 3px 3px 0 0;
//             }
//         }
//     }
// }


.tab-box-lr {
    position: relative;
    display: flex;
    overflow: hidden;

    &>.tab-contrl {
        height: 100%;
        z-index: 1;

        &>label {
            padding: 10px 16px 8px 16px;
            position: relative;
            display: block;
            border-radius: 2px 0 0 2px;
            z-index: 2;
            transition: border-right 0.3s;
            border-right: 2px solid transparent;
            cursor: pointer;
        }

        &>.tab-label-active {
            // background-color: $side_b;
            border-right: 2px solid $theme_color;
        }
    }

    &>.tab-container {
        border-left-width: 1px;
        border-left-style: solid;

        &>input[type="radio"] {
            display: none;
        }

        // 正常状态
        &>input[type="radio"]:checked+.tab-content {
            top: 0;
            visibility: visible;
            position: relative;
            opacity: 1;
            z-index: 1;
            transition: top .3s ease-out, opacity .3s ease-out, visibility .3s ease-out;
        }

        // 上部分
        &>input[type="radio"]:checked+.tab-content~.tab-content {
            top: 100%;
            visibility: hidden;
            position: absolute;
            opacity: 0;
            z-index: -1;
        }

        // 下部分
        &>.tab-content {
            position: absolute;
            top: -100%;
            background-color: #fff;
            border-radius: 3px;
            visibility: hidden;
            opacity: 0;
            z-index: -1;
        }
    }
}

.tab-box-tb {
    position: relative;
    overflow: hidden;
    // font-size: 16px;

    &>.tab-contrl {
        height: 100%;
        z-index: 1;

        &>label {
            padding: 10px 16px 8px 16px;
            position: relative;
            display: inline-block;
            z-index: 2;
            transition: border-bottom 0.3s;
            border-bottom: 2px solid transparent;
            cursor: pointer;
        }

        &>.tab-label-active {
            color: $tab_active_color;
            border-bottom: 2px solid $tab_active_color;
        }
    }

    &>.tab-container {
        border-top-width: 1px;
        border-top-style: solid;
        border-top-color: $tab_top_color;
        margin-top: -1px;

        &>input[type="radio"] {
            display: none;
        }

        // 正常状态
        &>input[type="radio"]:checked+.tab-content {
            left: 0;
            visibility: visible;
            display: block;
            position: relative;
            opacity: 1;
            z-index: 1;
        }

        // 上部分
        &>input[type="radio"]:checked+.tab-content~.tab-content {
            left: 100%;
            visibility: hidden;
            position: absolute;
            width: 100%;
            opacity: 0;
            z-index: -1;
        }

        // 下部分
        &>.tab-content {
            position: absolute;
            width: 100%;
            left: -100%;
            background-color: #fff;
            border-radius: 3px;
            visibility: hidden;
            opacity: 0;
            z-index: -1;
        }

        .transfer-all {
            transition: left .3s ease-out,
                opacity .3s ease-out,
                visibility .3s ease-out;
        }

        .transfer-simple {
            transition: opacity .3s ease-out;
        }
    }
}

.tab-box-simple {
    position: relative;
    overflow: hidden;

    &>.tab-contrl {
        height: 100%;
        z-index: 1;

        &>label {
            padding: 10px 16px 8px 16px;
            position: relative;
            display: inline-block;
            z-index: 2;
            transition: border-bottom 0.3s;
            border-bottom: 2px solid transparent;
            cursor: pointer;
        }

        &>.tab-label-active {
            color: $tab_active_color;
            border-bottom: 2px solid $tab_active_color;
        }
    }

    &>.tab-container {
        border-top-width: 1px;
        border-top-style: solid;
        border-top-color: $tab_top_color;
        margin-top: -1px;

        &>input[type="radio"] {
            display: none;
        }

        // 正常状态
        &>input[type="radio"]:checked+.tab-content {
            display: block;
            position: relative;
            visibility: visible;
            // opacity: 1;
            z-index: 1;
            // animation: tabSlideIn .3s;
        }

        // 上部分
        &>input[type="radio"]:checked+.tab-content~.tab-content {
            // display: none;
            // width: 100%;
            // opacity: 0;
            position: absolute;
            top: 0;
            visibility: hidden;
            z-index: -1;
        }

        // 下部分
        &>.tab-content {
            // width: 100%;
            // display: none;
            background-color: #fff;
            border-radius: 3px;
            // opacity: 0;
            position: absolute;
            top: 0;
            visibility: hidden;
            z-index: -1;
        }
    }
}

@keyframes tabSlideIn {
    0% {
        left: 100%;
        opacity: 0;
    }

    50% {
        left: 20%;
        opacity: 0.2;
    }

    100% {
        left: 0;
        opacity: 1;
    }
}

.details-normalize {

    .details-trigger[type="checkbox"]:checked+.details-content {
        position: absolute;
        top: -100%;
        opacity: 0;
        z-index: -99;
    }

    .details-content {
        transition: all .3s;
    }
}
